<%--
  Created by IntelliJ IDEA.
  User: 花未落雪柔眠
  Date: 2022/11/4
  Time: 13:13
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>Title</title>
    <script>
        function test(){
            try{
                var Message = "请选择文件夹";  //选择框提示信息
                var Shell = new ActiveXObject( "Shell.Application" );
                var Folder = Shell.BrowseForFolder(0,Message,0x0040,0x11);//起始目录为：我的电脑
                //var Folder = Shell.BrowseForFolder(0,Message,0); //起始目录为：桌面
                if(Folder != null){
                    Folder = Folder.items();  // 返回 FolderItems 对象
                    Folder = Folder.item();  // 返回 Folderitem 对象
                    Folder = Folder.Path;   // 返回路径
                    if(Folder.charAt(Folder.length-1) != "//"){
                        Folder = Folder + "//";
                    }
                    document.all.savePath.value=Folder;
                    return Folder;
                }
            }catch(e){
                alert(e.message);
            }
        }
    </script>
</head>
<body>
<h1>Hello 你的来到</h1>
<h3>上传页面</h3>
<form action="UploadServlet" method="post" enctype="multipart/form-data">

    资源上传：<input type="file" name="file"><br>

    <input type="submit">
</form>
<hr>
<a href="download/IO流.xmind" download="">IO流.xmind</a>
<a href="download/JavaScript.xmind" download="">JavaScript.xmind</a>
<a href="download/JDBC.xmind" download="">JDBC.xmind</a>
<a href="download/JSP.xmind" download="">JSP.xmind</a>
<a href="download/Maven.xmind">IO流</a>
<a href="download/MYSQL.xmind">MYSQL.xmind</a>
<a href="download/Request.xmind">Request.xmind</a>
<hr>
<form method="post" action="DownloadServlet">
    <input type="text"  name="fileName" placeholder="请输入要下载的文件名字">
    <input type="submit" value="下载">
</form>
<hr>
</body>
</html>
